#! /usr/bin/env python3  # linux autorun python 3
# -*- coding: UTF-8 -*-
"""
       Filename : run_cherrytree_app.py

       Copyright 2009-2014 Giuseppe Penone <giuspen@gmail.com>

       This program is free software; you can redistribute it and/or modify
       it under the terms of the GNU General Public License as published by
       the Free Software Foundation; either version 3 of the License, or
       (at your option) any later version.

       This program is distributed in the hope that it will be useful,
       but WITHOUT ANY WARRANTY; without even the implied warranty of
       MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
       GNU General Public License for more details.

       You should have received a copy of the GNU General Public License
       along with this program; if not, write to the Free Software
       Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
       MA 02110-1301, USA.
"""


import os
import sys
import cherrytree.app_cherrytree
import cherrytree.debug.debug_stuff as debug


ABS_DIR = os.path.dirname(os.path.realpath(__file__))
debug.debug_output("ABS_DIR = " + str(ABS_DIR), "info", "run_cherrytree_app.py", "")

sys.path.insert(0, ABS_DIR)   # add path to python so it can find the modules

# the start point of this program (Main in many lanauges)
if __name__ == '__main__':
    app = cherrytree.app_cherrytree.MyApplication()  # create the app object
    exit_status = app.run(sys.argv)  # run the app
    sys.exit(exit_status)  # exit the program